<html>
<head><meta charset="utf-8"><title>tidy --bless for trailing whitespace and etc? · t-compiler/help · Zulip Chat Archive</title></head>
<h2>Stream: <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/index.html">t-compiler/help</a></h2>
<h3>Topic: <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/tidy.20--bless.20for.20trailing.20whitespace.20and.20etc.3F.html">tidy --bless for trailing whitespace and etc?</a></h3>

<hr>

<base href="https://rust-lang.zulipchat.com">

<head><link href="https://rust-lang.github.io/zulip_archive/style.css" rel="stylesheet"></head>

<a name="243650494"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/tidy%20--bless%20for%20trailing%20whitespace%20and%20etc%3F/near/243650494" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> fee1-dead <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/tidy.20--bless.20for.20trailing.20whitespace.20and.20etc.3F.html#243650494">(Jun 23 2021 at 13:23)</a>:</h4>
<p>Currently, <code>tidy</code> only detects trailing whitespace and invalid (== 0 || &gt;= 2) trailing new lines. <br>
Should we introduce logic to tidy that automatically corrects these kinds of style issues? Or should this be a feature of rustfmt instead?</p>



<a name="243651796"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/tidy%20--bless%20for%20trailing%20whitespace%20and%20etc%3F/near/243651796" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Joshua Nelson <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/tidy.20--bless.20for.20trailing.20whitespace.20and.20etc.3F.html#243651796">(Jun 23 2021 at 13:32)</a>:</h4>
<p>I wouldn't ever expect it to trigger on rust files, rustfmt will catch those first. This is for markdown files and stuff I think.</p>



<a name="243651830"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/tidy%20--bless%20for%20trailing%20whitespace%20and%20etc%3F/near/243651830" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Joshua Nelson <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/tidy.20--bless.20for.20trailing.20whitespace.20and.20etc.3F.html#243651830">(Jun 23 2021 at 13:33)</a>:</h4>
<p>and those I would be wary of changing automatically because tidy doesn't understand the syntax</p>



<a name="243933812"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/tidy%20--bless%20for%20trailing%20whitespace%20and%20etc%3F/near/243933812" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> fee1-dead <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/tidy.20--bless.20for.20trailing.20whitespace.20and.20etc.3F.html#243933812">(Jun 25 2021 at 15:47)</a>:</h4>
<p><span class="user-mention silent" data-user-id="232545">Joshua Nelson</span> <a href="#narrow/stream/182449-t-compiler.2Fhelp/topic/tidy.20--bless.20for.20trailing.20whitespace.20and.20etc.3F/near/243651796">said</a>:</p>
<blockquote>
<p>I wouldn't ever expect it to trigger on rust files, rustfmt will catch those first. This is for markdown files and stuff I think.</p>
</blockquote>
<p>tidy is ran before rustfmt. am I missing some kind of option in config.toml that would make rustfmt properly format them?</p>



<a name="243934647"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/tidy%20--bless%20for%20trailing%20whitespace%20and%20etc%3F/near/243934647" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> bjorn3 <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/tidy.20--bless.20for.20trailing.20whitespace.20and.20etc.3F.html#243934647">(Jun 25 2021 at 15:53)</a>:</h4>
<p>Tidy does a rustfmt check run. Also you can run rustfmt yourself using <code>./x.py fmt</code>.</p>



<a name="243945648"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/tidy%20--bless%20for%20trailing%20whitespace%20and%20etc%3F/near/243945648" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Joshua Nelson <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/tidy.20--bless.20for.20trailing.20whitespace.20and.20etc.3F.html#243945648">(Jun 25 2021 at 17:24)</a>:</h4>
<p>If this tidy check runs before rustfmt I'd consider that a bug, since rustfmt will check and fix it anyway.</p>



<hr><p>Last updated: Aug 07 2021 at 22:04 UTC</p>
</html>